package com.dhcc.bpm.modules.log.service.impl;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.dhcc.bpm.modules.log.entity.TpsPeak;
import com.dhcc.bpm.modules.log.mapper.TpsPeakMapper;
import com.dhcc.bpm.modules.log.service.ITpsPeakService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.dhcc.bpm.modules.log.vo.GatewayLogDayVO;
import com.dhcc.bpm.modules.log.vo.TpsModelVO;
import com.dhcc.bpm.modules.log.vo.TpsPeakVO;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * <p>
 * tps峰值表 服务实现类
 * </p>
 *
 * @author xiafayu
 * @since 2021-05-31
 */
@Service
public class TpsPeakServiceImpl extends ServiceImpl<TpsPeakMapper, TpsPeak> implements ITpsPeakService {

    @Override
    public IPage<TpsPeakVO> selectTpsPeakPage(IPage<TpsPeakVO> page, TpsPeakVO tpsPeakVO) {
        return page.setRecords(baseMapper.selectTpsPeakPage(page, tpsPeakVO));

    }

    @Override
    public List<TpsModelVO> countNumBydate(GatewayLogDayVO gatewayLogDayVO) {
        return baseMapper.countNumBydate(gatewayLogDayVO);
    }

    @Override
    public List<TpsModelVO> countNumByYear(GatewayLogDayVO gatewayLogDayVO) {
        return baseMapper.countNumByYear(gatewayLogDayVO);
    }
}
